/**
 *  @FileName: BRRead.java
 *  @Last Modified Date: CharlW
 *  @Description: 从BufferedReader对象读取一个字符要使用read()方法
 */

import java.io.*;

public class BRRead {
	public static void main(String[] args) throws IOException {
		char c;
		// 使用 System.in 创建 BufferedReader
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		System.out.println("Enter characters, 'q' to quit.");
		// 读取字符
		do {
			c = (char) br.read();
			System.out.println(c);
		} while (c != 'q');
	}
}